pull: Do GPG verify commit objects when using deltas
authorColin Walters <walters@verbum.org>
Sun, 20 Nov 2016 21:17:22 +0000 (16:17 -0500)
committerAtomic Bot <atomic-devel@projectatomic.io>
Mon, 21 Nov 2016 15:55:09 +0000 (15:55 +0000)
commit41ef2aeb3824d52e33cb0d9eafa62393e5065fb0
tree69baf79d2c3d6dcdc0a4d2a3daa396dcc7d52f1b
parentcb57338a12819b0b1221cda62616a0aeb5d5f489
pull: Do GPG verify commit objects when using deltas

The fact that we weren't doing this is at best an oversight, and
for some deployment models a security vulnerability.  Having both
`gpg-verify` and `gpg-verify-summary` shows that we were intending
them to be orthogonal/independent.

Lately I've been advocating moving towards pinned TLS instead of
gpg-signed summaries, and if we follow that path, performing GPG
verification of commit objects even if using deltas is more important,
as it provides an at-rest verifiable authenticity and integrity
mechanism.

Content providers which are signing their summary files and/or using
TLS (particularly pinned TLS) for transport should treat this as a
nice-to-have.  However, for providers which are serving content over
plain HTTP and relying on GPG, this is a critical update.

Closes: https://github.com/ostreedev/ostree/issues/517
Closes: #589
Approved by: jlebon
src/libostree/ostree-repo-pull.c
tests/test-remote-gpg-import.sh